var tpl = _include('./index.html');
appendCss(_include('./index.less?_ac=less'));


var prizeList = {
    template: tpl,
    props:['prizes'],
    methods:{
        modifyPrize:function(data,index){
            window.sendMessage('createPrize.status',{data:data,index:index});
            window.onMessage('createPrize.save',function(data){
                Object.keys(data).forEach(function(key){
                    this.prizes[index][key] = data[key];
                }.bind(this))
            }.bind(this))
        }
    }
};

module.exports = prizeList;